package fiuba.adn2.dao.hibernate;

import java.util.List;

import fiuba.dao.hibernate.GenericDaoHibernate;
import fiuba.adn2.model.Noticia;
import fiuba.adn2.dao.NoticiaDao;

public class NoticiaDaoHibernate extends GenericDaoHibernate<Noticia, Long> implements NoticiaDao {

    public NoticiaDaoHibernate() {
        super(Noticia.class);
    }

    public List<Noticia> findByLastName(String lastName) {
        return getHibernateTemplate().find("from Noticia where lastName=?", lastName);
    }
}